package java2022_07_12;


import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStream;
import java.io.PrintWriter;

public class FileDemo13 {
    public static void main(String[] args) {
        try(OutputStream outputStream = new FileOutputStream("./test.txt")){
            try(PrintWriter writer = new PrintWriter(outputStream)){
                writer.println("hello 张三");
            }
        }catch(IOException e){
            e.printStackTrace();
        }
    }
}
